StockBorrowRate
This data is sourced from various clearing firms and typically represents their public borrow rates. Data is typically loaded once at the start of each trading day.\nStockBorrowRate records are published to the SpiderRock elastic cluster at the end of each trading period.
METADATA
Attribute | Value |
---|---|
Topic | 1725-client-borrow |
MLink Token | SRMLinkAnalytics |
Product | SRAnalytics |
accessType | SELECT |
Table Definition
Field | Type | Key | Default Value | Comment |
---|---|---|---|---|
ticker_at | enum - AssetType | PRI | 'None' | |
ticker_ts | enum - TickerSrc | PRI | 'None' | |
ticker_tk | VARCHAR(12) | PRI | '' | |
clientFirm | VARCHAR(16) | PRI | '' | clientFirm if clientFirm specific rates default SR system default rates |
gcFlag | enum - YesNo | 'None' | General collateral flag Yes No | |
gcRate | FLOAT | 0 | General collateral rate | |
borrowRate | FLOAT | 0 | StockBorrow rate | |
timestamp | DATETIME(6) | '1900-01-01 00:00:00.000000' |
PRIMARY KEY DEFINITION (Unique)
Field | Sequence |
---|---|
ticker_tk | 1 |
ticker_at | 2 |
ticker_ts | 3 |
clientFirm | 4 |
CREATE TABLE EXAMPLE QUERY
CREATE TABLE `SRAnalytics`.`MsgStockBorrowRate` (
`ticker_at` ENUM('None','EQT','IDX','BND','CUR','COM','FUT','SYN','WAR','FLX','MUT','SPD','MM','MF','COIN','TOKEN','ANY') NOT NULL DEFAULT 'None',
`ticker_ts` ENUM('None','SR','NMS','CME','ICE','CFE','CBOT','NYMEX','COMEX','RUT','CIDX','ARCA','NYSE','OTC','NSDQ','MFQS','MIAX','DJI','CUSIP','ISIN','BXE','EUX','ANY','CXE','DXE','NXAM','NXBR','NXLS','NXML','NXOS','NXP','EUREX','CEDX','ICEFE') NOT NULL DEFAULT 'None',
`ticker_tk` VARCHAR(12) NOT NULL DEFAULT '',
`clientFirm` VARCHAR(16) NOT NULL DEFAULT '' COMMENT 'clientFirm (if clientFirm specific rates); <default> = SR system default rates',
`gcFlag` ENUM('None','Yes','No') NOT NULL DEFAULT 'None' COMMENT 'General collateral flag: Yes; No',
`gcRate` FLOAT NOT NULL DEFAULT 0 COMMENT 'General collateral rate',
`borrowRate` FLOAT NOT NULL DEFAULT 0 COMMENT 'StockBorrow rate',
`timestamp` DATETIME(6) NOT NULL DEFAULT '1900-01-01 00:00:00.000000',
PRIMARY KEY USING HASH (`ticker_tk`,`ticker_at`,`ticker_ts`,`clientFirm`)
) ENGINE=SRSE DEFAULT CHARSET=LATIN1 COMMENT='This data is sourced from various clearing firms and typically represents their public borrow rates. Data is typically loaded once at the start of each trading day.\nStockBorrowRate records are published to the SpiderRock elastic cluster at the end of each trading period.';
SELECT TABLE EXAMPLE QUERY
SELECT
`ticker_at`,
`ticker_ts`,
`ticker_tk`,
`clientFirm`,
`gcFlag`,
`gcRate`,
`borrowRate`,
`timestamp`
FROM `SRAnalytics`.`MsgStockBorrowRate`
WHERE
/* Replace with a ENUM('None','EQT','IDX','BND','CUR','COM','FUT','SYN','WAR','FLX','MUT','SPD','MM','MF','COIN','TOKEN','ANY') */
`ticker_at` = 'None'
AND
/* Replace with a ENUM('None','SR','NMS','CME','ICE','CFE','CBOT','NYMEX','COMEX','RUT','CIDX','ARCA','NYSE','OTC','NSDQ','MFQS','MIAX','DJI','CUSIP','ISIN','BXE','EUX','ANY','CXE','DXE','NXAM','NXBR','NXLS','NXML','NXOS','NXP','EUREX','CEDX','ICEFE') */
`ticker_ts` = 'None'
AND
/* Replace with a VARCHAR(12) */
`ticker_tk` = 'Example_ticker_tk'
AND
/* Replace with a VARCHAR(16) */
`clientFirm` = 'Example_clientFirm';
Doc Columns Query
SELECT * FROM SRAnalytics.doccolumns WHERE TABLE_NAME='StockBorrowRate' ORDER BY ordinal_position ASC;